home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 22 / Cream of the Crop 22.iso / bbs / maxkit25.zip / MAXMNT25.ARJ / MAXMNT25.MEX next >
Text File  |  1996-11-15  |  23KB  |  667 lines

  1.  
  2. // ──────────────────────────────────────────────────────────────────────────
  3. // Copyright 1995 1996 1997 by Gerry Ellison.  All rights reserved.
  4. // File: maxmnt25.mex v2.50 by Gerry Ellison          1:108/107
  5. //                Free for non-commerical use.
  6. //
  7. // Desc: Routine to detect and ask for Ansi.
  8. // Desc: Routine to save and turn on hotkey.
  9. // Desc: Routine to ask for user's gender.
  10. // Desc: Routine to enter birth, use zeros or skip entirely
  11. // Desc: Routine to enter a formatted voice & dataphone number.
  12. // Desc: Routine to correct Password under six characters, or encripted.
  13. // Desc: Routine to enter or correct City, State, Zip and Country.
  14. //
  15. // Thanks for phone format idea phone.mex 1.5 by David Osborne 1:243/2
  16. // ──────────────────────────────────────────────────────────────────────────
  17.  
  18. #define INCL_global
  19. #define INCL_max_chng
  20. #include <max.mh>
  21. #include <language.mh>
  22.  
  23.   int: Ch, Done, Flag, SaveVideo, SaveHot;
  24.   string: Country, EnterData, TempStr;
  25.  
  26. //==========================  functions  ===================================
  27. int checkansi() {
  28.    Ch := input_list("?Yn|", 0, "", "",
  29.          "\nDoes your system support "COL_YELLOW"ANSI"
  30.             COL_GRAY" screen controls");
  31.    if (Ch = 89 or Ch = 124) {
  32.        SaveVideo := TRUE;
  33.        // usr.fsr:=TRUE;       // Force FSR
  34.        // usr.ibmchars:=TRUE;  // Force IBM chars
  35.        // usr.cls:=TRUE;       // Force CLS
  36.        // usr.bored:=0;        // Force FSE
  37.        }
  38.      else if (Ch = 78) {
  39.               SaveVideo := FALSE;
  40.               usr.video := TRUE;
  41.          }
  42.        else
  43.          if (Ch = 63)
  44.             menu_cmd(609,"");   //show video menu, Ansi is on at this time.
  45.  
  46.    return SaveVideo;
  47. }                                                //end checkansi
  48.  
  49.  
  50. int hotkey(int: Flag) {
  51.     if (Flag = 1) {
  52.     if (usr.hotkeys = FALSE)
  53.         menu_cmd(615,"");                        // Turn on Hot Keys
  54.         }
  55.     else
  56.       if (usr.hotkeys = TRUE)
  57.           menu_cmd(615,"");                      // Turn off Hot Keys
  58.     return SaveHot;
  59. }                                                //end hotkey
  60.  
  61.  
  62. void gender() {
  63.     string: skeys;
  64.     skeys := str_sex_keys;
  65.   do {                                           //begin do
  66.     Done := TRUE;
  67.     Ch := input_list("mfn", 0, "", "",
  68.            COL_GRAY"\nPlease enter your Gender: "
  69.            COL_YELLOW"M"COL_GRAY")ale, "
  70.            COL_YELLOW+"F"COL_GRAY")emale, or "
  71.            COL_YELLOW+"N"+COL_GRAY")ot Given?");
  72.  
  73.     if (Ch >= 'a' and Ch <= 'z')
  74.         Ch:=Ch + 'A' - (Ch - 'a');               // Uppercase it
  75.  
  76.     if (Ch=skeys[1])
  77.         usr.sex := SEX_MALE;
  78.       else if (Ch=skeys[2])
  79.                usr.sex := SEX_FEMALE;
  80.         else {
  81.           usr.sex := SEX_UNKNOWN;
  82.           print(AVATAR_UP+AVATAR_CLEOL"\rIt will be entered as "
  83.                 COL_YELLOW"Gender Unknown, "COL_GRAY);
  84.     Ch := input_list("yn|", 0, "", "","Should I enter this?");
  85.           if (Ch <> 89)
  86.               Done := FALSE;
  87.               print(AVATAR_UP+AVATAR_CLEOL);
  88.               print(AVATAR_UP+AVATAR_CLEOL);
  89.               }
  90.   }                                              //end do
  91.   while (Done <> TRUE);
  92. }                                                //end gender
  93.  
  94.  
  95. void enterbirth() {
  96.     string: birth, choice, mask;
  97.  
  98.     print(COL_GRAY"\n\aYour "COL_YELLOW"BIRTHDAY"
  99.           COL_GRAY" has not been entered or was entered incorrectly.");
  100.     Ch := input_list("yN|", 0, "", "",
  101.           "\nYear can be entered as Zeros, do you wish to enter now");
  102.     if (Ch = 89) {                                // start yes
  103.         print(AVATAR_UP+AVATAR_CLEOL);
  104.         EnterData := "Thanks, Please enter your BIRTHDAY: ";
  105.         mask          := EnterData + "yyyy-mm-dd";
  106.     Done := False;
  107.     while (Done <> TRUE) {                       // Start While
  108.       birth := "";
  109.       do {                                       // Start Do While
  110.         if (strlen(birth)=0)
  111.             birth := EnterData;
  112.  
  113.     if (strlen(birth)=strlen(EnterData)+4)
  114.         birth := birth + ".";
  115.  
  116.     if (strlen(birth)=strlen(EnterData)+7)
  117.         birth := birth + ".";
  118.  
  119.     print("\r"COL_YELLOW+mask+COL_GRAY"\r"+birth);
  120.     choice := "0123456789";
  121.     if (strlen(birth)=(strlen(EnterData)+5))
  122.         choice := "01";
  123.     if (strlen(birth)=(strlen(EnterData)+6))
  124.         choice := "0123456789";
  125.     if (strlen(birth)=(strlen(EnterData)+8))
  126.         choice := "0123";
  127.     if (strlen(birth)=(strlen(EnterData)+9))
  128.         choice := "0123456789";
  129.     Ch := input_list(choice, CINPUT_FULLPROMPT |
  130.     CINPUT_NOLF, "", "\r"+mask+"\r"+birth, "");
  131.     birth := birth + itostr(Ch-48);
  132.     }                                            // End Do While
  133.     while (strlen(birth)<>strlen(EnterData)+10);
  134.  
  135.     birth := substr(birth,strlen(birth)-9,10);
  136.  
  137.     Ch := input_list("|Yn", 0, "", "",
  138.           "You entered as your Birthday, "COL_YELLOW+birth+
  139.           COL_GRAY" is it OK to enter it?");
  140.     if (Ch = 89 or Ch = 124)
  141.         Done := TRUE;
  142.      else
  143.        print(AVATAR_UP+AVATAR_CLEOL);
  144.      }                                           // end yes
  145.   }                                              // End While
  146.   usr.dob := birth;
  147. }                                                //end enterbirth
  148.  
  149. //p
  150. void password() {
  151.     string: mask, TempStr;
  152.  
  153.     print(COL_GRAY"\n\aYour "COL_YELLOW"PASSWORD"COL_GRAY
  154.           " has not been entered or was entered incorrectly\n");
  155. do {                                             //begin do
  156.     EnterData := "Please enter at least a six character Password";
  157.     mask      := EnterData + COL_YELLOW" ...............";
  158.     TempStr   := EnterData + " ";
  159.  
  160.     print("\r"COL_YELLOW+mask+COL_GRAY"\r"+TempStr);
  161.  
  162.     Ch:=input_ch(CINPUT_NOLF,"");
  163.     if (Ch = 124 or Ch = ' ') {
  164.         Done := FALSE;
  165.         }
  166.       else {                                     //else1
  167.         input_str(TempStr, INPUT_WORD | INPUT_ALREADYCH, Ch, 15, "");
  168.  
  169.     if (strlen(TempStr) < 4) {
  170.         Done := FALSE;
  171.         print(AVATAR_UP+AVATAR_CLEOL);
  172.         }
  173.       else {
  174.         print(AVATAR_UP+AVATAR_CLEOL"\r"COL_GRAY"You entered a "+
  175.               itostr(strlen(TempStr))+" digit password "
  176.               COL_YELLOW+TempStr+COL_GRAY", is it OK to enter?");
  177.     Ch := input_list("yN|", 0, "", "", "");
  178.     if (Ch <> 89) {
  179.         Done := FALSE;
  180.         print(AVATAR_UP+AVATAR_CLEOL);
  181.         }
  182.       else
  183.         Done := TRUE;
  184.         }
  185.      }                                           //end else1
  186.   }                                              //end do
  187.   while(Done <> TRUE);
  188.  
  189.   usr.pwd := TempStr;
  190. }                                                // end Password
  191.  
  192.  
  193. //c
  194. string getcountry() {
  195.     print(COL_GRAY"Are you calling from the, "COL_YELLOW"U"COL_GRAY"SA, "
  196.           COL_YELLOW"C"COL_GRAY"anada, or "
  197.           COL_YELLOW"A"COL_GRAY"nother country?");
  198.     Ch := input_list("Uca", 0, "", "",""); {
  199.     if (Ch = 85 or Ch = 124)
  200.         Country := "USA";
  201.     if (Ch = 67)
  202.         Country := "CND";
  203.     if (Ch = 65) {                               // begin enter country
  204.     string: choice, mask;
  205.     Flag := 0;
  206.   while (Flag <> 1) {                            //begin while
  207.     EnterData := "";
  208.   do {                                           //begin do
  209.     mask := "";
  210.     TempStr := COL_GRAY"\rPlease enter your "
  211.                COL_YELLOW"COUNTRY"COL_GRAY" only:";
  212.     mask    := TempStr + COL_YELLOW" .............";
  213.  
  214.     if (strlen(EnterData) = 0)
  215.         EnterData := TempStr + " ";
  216.  
  217.     print(AVATAR_UP+AVATAR_CLEOL+mask+COL_GRAY"\r"+EnterData);
  218.  
  219.     Ch:=input_ch(CINPUT_NOLF,"");
  220.         if (Ch < 65 or Ch > 90) {
  221.             Done := FALSE;
  222.             print(AVATAR_DOWN);
  223.             }
  224.           else
  225.            {                                     //begin else1
  226.     input_str(EnterData, INPUT_LB_LINE | INPUT_ALREADYCH, Ch, 25, "");
  227.  
  228.     if (strlen(EnterData) >=3)
  229.         Done := TRUE;
  230.       else
  231.         Done := FALSE;
  232.         print(AVATAR_UP+AVATAR_CLEOL);
  233.    }                                             //end else1
  234.   } while (Done <> TRUE);                        //end do
  235.  
  236.     print(AVATAR_CLEOL"\rYou entered as your country as "
  237.           COL_YELLOW+EnterData+ COL_GRAY", is it OK to enter");
  238.     Ch := input_list("|Yn", 0, "", "","");
  239.     if (Ch = 89 or Ch = 124)
  240.         Flag := 1;
  241.         }                                        //end while
  242.     Country :=strupper(substr(EnterData,1,3));
  243.   }                                              // end enter country
  244.  }
  245.   return Country;
  246. }                                                //end getcountry
  247.  
  248.  
  249. //ph
  250. void uscdphone(ref int: Flag) {
  251.     int: Done;
  252.     string: choice, phone, mask;
  253.  
  254.     if (Flag = 'V')
  255.         TempStr := " VOICE ";
  256.       else
  257.         TempStr := " DATA ";
  258.  
  259.     EnterData := "Please enter your"COL_YELLOW+TempStr+
  260.                    COL_GRAY"phone number:";
  261.  
  262.   while (Done <> TRUE) {                         //start while
  263.     mask  := EnterData + " (...) ...-....";
  264.     phone := EnterData + " (";
  265.  
  266.   do {                                           //start Do
  267.     if (strlen(phone)=strlen(EnterData)+5)
  268.         phone := phone + ") ";
  269.  
  270.     if (strlen(phone)=strlen(EnterData)+10)
  271.         phone := phone + "-";
  272.  
  273.     print("\r"COL_YELLOW+mask+"\r"+phone);
  274.     choice := "0123456789";
  275.     if (strlen(phone)=(strlen(EnterData)+2))
  276.         choice := "23456789";
  277.     if (strlen(phone)=(strlen(EnterData)+6))
  278.         choice := "23456789";
  279.     Ch := input_list(choice, CINPUT_FULLPROMPT |
  280.           CINPUT_NOLF, "", "\r"+mask+"\r"+phone, "");
  281.  
  282.     phone := phone + itostr(Ch-48);
  283.   }                                              // End Do
  284.   while (strlen(phone)<>strlen(EnterData)+15);
  285.  
  286.     print("\r",mask,"\r",phone);
  287.  
  288.     print("\rYou entered,"COL_YELLOW+TempStr+
  289.           substr(phone,strlen(phone)-13,14)+
  290.           COL_GRAY", is it OK to enter");
  291.     Ch := input_list("|Yn", 0, "", "","");
  292.     if (Ch = 89 or Ch = 124)
  293.         Done := TRUE;
  294.       else
  295.         print(AVATAR_UP+AVATAR_CLEOL);
  296.   }                                              //end while
  297.     if (Flag = 'V')
  298.         usr.phone   := substr(phone,strlen(phone)-13,14);
  299.       else
  300.         usr.dataphone   := substr(phone,strlen(phone)-13,14);
  301. }                                                //end uscdphone
  302.  
  303. //oph
  304. void othphone(ref int: Flag) {
  305.     int: Done;
  306.     string: choice, mask, phone;
  307.  
  308.     if (Flag = 'V')
  309.         TempStr := "VOICE";
  310.       else
  311.         TempStr := "DATA";
  312.  
  313.     EnterData := COL_GRAY"Please enter your "COL_YELLOW+TempStr+
  314.                  COL_GRAY" phone number:";
  315.  do {                                            //begin do
  316.     mask := EnterData + COL_YELLOW"...............";
  317.     phone := EnterData + " ";
  318.  
  319.     if (Flag = 'V')
  320.         TempStr := " VOICE ";
  321.       else
  322.         TempStr := " DATA ";
  323.  
  324.     print(AVATAR_UP+AVATAR_CLEOL"\r"COL_YELLOW+mask+"\r"+phone);
  325.  
  326.     Ch:=input_ch(CINPUT_NOLF,"");
  327.          if (Ch = 124 or Ch = ' ')
  328.              Done := FALSE;
  329.            else {                                //else1
  330.     if (Ch>='A' and Ch<='Z')
  331.         choice := "1234567890";
  332.         input_str(phone, INPUT_LB_LINE | INPUT_ALREADYCH, Ch, 15, "");
  333.  
  334.     print(AVATAR_UP+AVATAR_CLEOL"\rYou entered,"COL_YELLOW+TempStr+phone+
  335.           COL_GRAY", is it OK to enter");
  336.         Ch := input_list("|Yn", 0, "", "","");
  337.  
  338.         if (Ch = 89 or Ch = 124)
  339.             Done := TRUE;
  340.   }                                              //end else1
  341.   }                                              //end do
  342.   while (Done <> TRUE);
  343.  
  344.     if (Flag = 'V')
  345.         usr.phone := phone;
  346.       else
  347.         usr.dataphone := phone;
  348. }                                                //end othphone
  349.  
  350. void dataphone(ref int: Flag) {
  351.     print("Is your "COL_YELLOW"VOICE & DATA"
  352.           COL_GRAY" phone number the same number");
  353.  
  354.     Ch := input_list("yN|", 0, "", "","");
  355.     if (Ch = 89)
  356.         usr.dataphone   := usr.phone;
  357.       else if (Flag <> 'O') {
  358.                Flag := 'D';
  359.                print(AVATAR_UP+AVATAR_CLEOL);
  360.                uscdphone(Flag);
  361.                }
  362.          else {
  363.            Flag := 'D';
  364.            print(AVATAR_UP+AVATAR_CLEOL);
  365.            othphone(Flag);
  366.            }
  367. }                                                //end dataphone
  368.  
  369.  
  370.  
  371. //l
  372. void getlocation() {
  373.   int: i;
  374.   string: choice, location, mask;
  375.   print("\n");
  376.   Flag := 1;
  377.   while (Flag <> 0) {                            // begin redo location
  378.     print(AVATAR_CLEOL+COL_GRAY"Your "COL_YELLOW"CITY, STATE & ZIP"
  379.           COL_GRAY" has not been entered or was entered incorrectly.\n");
  380.     getcountry();
  381.   {                                              // begin city
  382.   string: city, c1, c2;
  383.   do {
  384.     EnterData := "";
  385.     TempStr   := "";
  386.     location  := "";
  387.     TempStr   := COL_GRAY"\rPlease enter your "COL_YELLOW"CITY"
  388.                  COL_GRAY"  only:";
  389.     mask      := TempStr + " .............";
  390.  
  391.     if (strlen(EnterData)=0)
  392.         EnterData := TempStr + " ";
  393.  
  394.     print("\r"COL_YELLOW+mask+COL_GRAY"\r"+EnterData);
  395.  
  396.     Ch:=input_ch(CINPUT_NOLF,"");
  397.         if (Ch = 124 or Ch < 58)
  398.             Done := FALSE;
  399.            else {                                //else1
  400.     input_str(EnterData, INPUT_LB_LINE | INPUT_ALREADYCH, Ch, 25, "");
  401.  
  402.     c1   := strupper(substr(EnterData,1,1));
  403.     c2   := strlower(substr(EnterData,2,stridx(EnterData,1,' ')-1));
  404.     city := strupper(substr(EnterData,stridx(EnterData,1,' ')+1,1))+
  405.             strtrim(strlower(substr(EnterData,stridx(EnterData,1,' ')+
  406.             2,strlen(EnterData))),".,");
  407.  
  408.     if (c2 <> "")
  409.         city := c1+c2+city;
  410.  
  411.     if (city = "Cincy" or city = "Cinti" or city = "Cin")
  412.         city := "Cincinnati";
  413.     if (strlower(city) = "ham")
  414.         city := "Hamilton";
  415.     if (strlower(city) = "cov")
  416.         city := "Covington";
  417.     if (substr(strlower(city),1,13) = "hidden valley")
  418.         city := "Hidden Valley Lk.";
  419.     if (strlower(city) = "city") {
  420.         Done := FALSE;
  421.         EnterData := "";
  422.         print(AVATAR_UP);
  423.         }
  424.       else
  425.         Done := TRUE;
  426.     }                                            //end else1
  427.   }
  428.   while (Done <> TRUE);                          //end do
  429.          location := city + ", ";
  430.   }                                              // end city
  431.  
  432.  
  433. {                                                //begin state
  434.     string: state;
  435.  
  436.     If (Country <> "CND")
  437.          state := " STATE ";
  438.       else
  439.          state := "PROVINCE";
  440.   do {
  441.     TempStr := "Please enter your "COL_YELLOW+state+
  442.                  COL_GRAY" abbreviation.:";
  443.  
  444.     mask       := COL_GRAY+TempStr + " ..";
  445.     EnterData    := TempStr + " ";
  446.     print(AVATAR_UP+AVATAR_CLEOL+"\r"COL_YELLOW+mask+
  447.           COL_GRAY"\r"+EnterData);
  448.  
  449.     Ch:=input_ch(CINPUT_NOLF,"");
  450.     if (Ch = 124 or Ch < 58) {
  451.         Done := FALSE;
  452.         print(AVATAR_DOWN);
  453.         }
  454.       else {                                     //else1
  455.     if (Ch>='A' and Ch<='Z')
  456.     input_str(EnterData, INPUT_WORD | INPUT_ALREADYCH, Ch, 2, "");
  457.     if (strlen(EnterData) <> 2) {
  458.         Done := FALSE;
  459.         }
  460.       else
  461.         Done := TRUE;
  462.         }                                        //end else1
  463.     }
  464.     while (Done <> TRUE);                        //end do
  465.  
  466.     location :=location + strupper(EnterData);
  467.   }                                             //end state
  468.  
  469.  
  470. //z
  471. {                             // begin all zips
  472.     string: zip;
  473.  
  474.     print(AVATAR_UP+AVATAR_CLEOL);
  475.     EnterData := "\rPlease enter your "COL_YELLOW"ZIP"COL_GRAY" code:";
  476.  
  477. if (Country = "USA") {                           //begin USA zip
  478.     mask          := EnterData + " ..........";
  479.  
  480.   do {                                           // begin Do
  481.     if (strlen(zip)=0)
  482.         zip := EnterData + " ";
  483.  
  484.         if (strlen(zip) = 40)
  485.             zip := zip + "-";
  486.  
  487.     print(COL_YELLOW+mask+COL_GRAY"\r"+(zip));
  488.  
  489.     if (strlen(zip) <> 41)
  490.         choice := "1234567890";
  491.       else
  492.         choice := "1234567890|";
  493.  
  494.     Ch := input_list(choice, CINPUT_FULLPROMPT |
  495.            CINPUT_NOLF, "", "\r"+mask+"\r"+zip, "");
  496.  
  497.     if (Ch = 124)
  498.         zip := zip + "0000";
  499.  
  500.     zip := zip + itostr(Ch-48);
  501.  
  502.     }                                            // End Do
  503.     while (strlen(zip) < 45);
  504.  
  505.     zip := substr(zip,35,11);
  506.  
  507.     }                                            //end USA zip
  508. else
  509.   {                                              // begin other then USA zip
  510. do {
  511.     EnterData := "\rPlease enter your ZIP code:";
  512.          mask := EnterData + " ........";
  513.           zip := EnterData + " ";
  514.  
  515.     print("\r"COL_YELLOW+mask+COL_GRAY"\r"+zip);
  516.  
  517.     Ch:=input_ch(CINPUT_NOLF,"");
  518.         if (Ch = 124 or Ch = ' ')
  519.             Done := FALSE;
  520.           else {
  521.             if (Ch>='A' and Ch<='Z')
  522.             choice := "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789";
  523.             input_str(zip, INPUT_LB_LINE | INPUT_ALREADYCH, Ch, 8, "");
  524.             }
  525.     if (strlen(zip) < 6)
  526.         Done := FALSE;
  527.       else
  528.         Done := TRUE;
  529.     }
  530.     while (Done <> TRUE);
  531.  
  532.     zip := " "+strupper(zip);
  533. }                                                // end other then USA zip
  534.  
  535.     location := location+zip+"  "+Country;
  536.  
  537.     if (Country <> "USA")
  538.         print(AVATAR_UP+AVATAR_CLEOL);
  539.     print("You entered "COL_YELLOW+location+
  540.           COL_GRAY", is it OK to enter");
  541.     Ch := input_list("|Yn", 0, "", "","");
  542.        if (Ch = 89 or Ch = 124)
  543.            Flag := 0;
  544.          else {
  545.            Flag := 1;
  546.            EnterData := "";
  547.            if (Country <> "USA");
  548.                print(AVATAR_UP+AVATAR_CLEOL);
  549.            for (i := 1; i < 3; i := i + 1) {
  550.            print(AVATAR_UP+AVATAR_CLEOL);
  551.            }
  552.            }
  553.       }                                          // begin redo location
  554.  
  555.     usr.city := location;
  556.   }                                              // end all zips
  557. }                                                //end getlocation
  558.  
  559. //m=========================================================================
  560. int main(string: argv) {                         // Begin Main Procedue
  561.  
  562.     int: loop;
  563.     string: mask, choice;
  564.  
  565.     SaveVideo := usr.video;
  566.  
  567.     if(ansi_detect()=TRUE)
  568.     if (usr.video = FALSE) {
  569.         usr.video := TRUE;
  570.         checkansi();
  571.         }
  572.  
  573.     SaveHot := usr.hotkeys;                      // Save Hot Key setting      │
  574.     Flag :=1;                                    //turn on kotkey
  575.     hotkey(Flag);
  576.  
  577.     If (usr.sex = SEX_UNKNOWN)
  578.         gender();                                //ask gender
  579.  
  580.     if (usr.dob = "1900.00.00" or usr.dob = "0000.00.00") // begin birthday
  581.         enterbirth();                            // begin birthday.
  582.  
  583. //  Uncomment in  Max.ctl "No Password Encryption" then switch the two lines
  584. //  below. It will ask for a new unencryption password.
  585.  
  586. //    if (strlen(usr.pwd) < 6 or usr.encrypted = TRUE)
  587.     if (strlen(usr.pwd) < 6) // begin Password
  588.     password();
  589.  
  590.  if (strlen(usr.dataphone) <9 or strlen(usr.dataphone) <> 14 or
  591.      strlen(usr.phone) <9 or strlen(usr.phone) <> 14)
  592.  {                                               //begin voice & dataphone
  593.     print(COL_GRAY"\nYour "COL_YELLOW" PHONE NUMBER"COL_GRAY
  594.           " has not been entered or was entered incorrectly.\n");
  595.  
  596.     getcountry();
  597.  
  598.     if (Country <> "OTH") {                      // begin US & Canada phone
  599.     if (strlen(usr.phone) <> 14)
  600.         {
  601.         Flag := 'V';
  602.         uscdphone(Flag);
  603.         }
  604.     if (strlen(usr.dataphone) <> 14)
  605.        {
  606.        Flag := 'D';
  607.        dataphone(Flag);
  608.        }
  609.  }                                               //end US & Canada phone
  610.  
  611.     if (Country = "OTH")                         // begin OTH phone
  612.     {
  613.     if (strlen(usr.phone) <10)
  614.     {                                            // begin OTH voicephone
  615.         Flag := 'V';
  616.         othphone(Flag);
  617.         }
  618.     if (strlen(usr.dataphone) <10)
  619.     {                                            // begin OTH dataphone
  620.          Flag := 'O';
  621.          dataphone(Flag);
  622.          }
  623.     }                                            // end OTH dataphone
  624. }                                                //end voice & dataphone
  625.  
  626.      if (strlen(usr.city) <24)                        // begin city state zip
  627.          getlocation();
  628. // ────────────────────────────── Restore Key ──────────────────────────────
  629.  
  630.     usr.video   := SaveVideo;                    // Restore video setting
  631.     usr.hotkeys := SaveHot;                      // Restore hotkey setting
  632.     return 0;
  633. }                                                // End Main Procedue
  634. //////////////////////////////////////////////////////////////////////////
  635. // Not in program
  636. // ─────────────────────────────── RIP ─────────────────────────────────────
  637. /// if(rip_detect()=TRUE)
  638. ///   ch := input_list("Yn?", 0, "", "",
  639. ///         "\nDoes your system support Remote Imaging Protocol (RIP) ");
  640. ///       if (ch = 63)
  641. ///           display_file("C:\\Max\\Misc\\Why_ANSI.bbs", nonstop);
  642. ///   ch := input_list("Yn?", 0, "", "",
  643. ///         "\nDoes your system support Remote Imaging Protocol (RIP) ");
  644. ///       if (ch = 89)
  645. ///           usr.rip := TRUE;                         // Force RIP on
  646. // ────────────────────────────── Editor ───────────────────────────────────
  647. // Use the MaxEd full-screen editor [Y,n,?=help]?
  648. ///     ch := input_list("Yn?", 0, "", "",
  649. ///           "\nD0 you use the MaxEd full-screen editor?");
  650. ///         if (ch = 63)
  651. ///             display_file("C:\\Max\\Misc\\Why_FSED.bbs", nonstop);
  652. ///         if (ch = 78)
  653. ///             usr.bored:=0;                       // Force bored
  654. ///         else
  655. ///             usr.fsr:=TRUE;                             // Force FSR
  656. // ────────────────────────────── IBM-PC ───────────────────────────────────
  657. // Use IBM-PC characters [Y,n,?=help]?
  658. ///     ch := input_list("Yn?", 0, "", "", "\nDo you use IBM-PC characters?");
  659. ///         if (ch = 63)
  660. ///             display_file("C:\\Max\\Misc\\Why_PC.BBS", nonstop);
  661. ///         if (ch <> 89)
  662. ///             usr.ibmchars:=TRUE;                 // Force IBM chars
  663. //..////////////////////////////////////////////////////////////////////////
  664. // if (argv <> "UPDATE") {
  665. //    char: nonstop;
  666. //    nonstop := 0;
  667.